package com.views
{
	import com.GameModel;
	import com.controllers.GameController;
	
	import flash.display.Sprite;

	public class GameUILayerView extends Sprite
	{
		
		private var _ctrl:GameController;
		private var _uiView:UI;
		private var _time:int = 60;
		public function GameUILayerView(p_ctrl:GameController)
		{
			super();
		}
		public function createView():void{//创建UI
			if(!_uiView)_uiView = new UI;
			this.addChild(_uiView);
			_uiView.x = 450;
			_uiView.y = 22
		}
		public function updataView():void{
			_uiView.level.text = String(GameModel.getInstance().level);
			_uiView.score.text = String(GameModel.getInstance().score);
		}
		public function updateViewSecond():void{
			_time--;
			_uiView.time.text = String(_time);
		}
		
	}
}